package com.example.spring_mvc.mapper;

import com.example.spring_mvc.dao.User;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: fzykd
 * Date: 2023-03-30
 * Time: 10:52
 */
@Mapper
public interface UserMapper {
    //查询所有数据
    List<User> selectAll();

    //新增一条数据
    int addOne(User user);


    //删除用户
    int removeId(Integer id);

    //修改用户
    int Update(User user);

    //批量删除用户
    void removeIds(List<Integer> ids);

    User selectOne(String name, String password);
}
